<?php
/**
 * Common Template - tpl_footer.php
 *
 * this file can be copied to /templates/your_template_dir/pagename<br />
 * example: to override the privacy page<br />
 * make a directory /templates/my_template/privacy<br />
 * copy /templates/templates_defaults/common/tpl_footer.php to /templates/my_template/privacy/tpl_footer.php<br />
 * to override the global settings and turn off the footer un-comment the following line:<br />
 * <br />
 * $flag_disable_footer = true;<br />
 *
 * @package templateSystem
 * @copyright Copyright 2003-2010 Zen Cart Development Team
 * @copyright Portions Copyright 2003 osCommerce
 * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
 * @version $Id: tpl_footer.php 15511 2010-02-18 07:19:44Z drbyte $
 */
require(DIR_WS_MODULES . zen_get_module_directory('footer.php'));
?>

<?php
if (!isset($flag_disable_footer) || !$flag_disable_footer) {
?>
<div id="collapseFooterWrapper"><span class="collapseFooter" data-toggle="collapse" data-target="#footerWidgetWrapper" data-my-tooltip="tooltip" title="<?php echo TEXT_SHOW_HIDE_FOOTER; ?>"></span></div>
<div id="footerWidgetWrapper" class="collapse in">
<div id="footerWidget" class="row-fluid">
    <section id="aboutUsFooter" class="span3">
        <h3 class="footerBoxHeading"><?php echo TEXT_ABOUT_US; ?></h3>
        <p><?php echo REVELATION_ABOUT_US; ?></p>
    </section>
    <section id="contactFooter" class="span3">
    <h3 class="footerBoxHeading"><?php echo TEXT_CONTACT_US; ?></h3>    
        <div id="contactFooterContent">
            <?php if(defined('REVELATION_STORE_LOCATION') && REVELATION_STORE_LOCATION != '') { ?>
            <div class="contactDetailsWrapper">
                <div class="contactIcon"><span id="storeAddress" class="contactDetails"><i class="icon-home"></i></span></div>
                <span class="contactEntry"><?php echo REVELATION_STORE_LOCATION; ?></span>
            </div>
            <?php } ?>
            <?php if(defined('REVELATION_STORE_PHONE') && REVELATION_STORE_PHONE != '') { ?>
            <div class="contactDetailsWrapper">
                <div class="contactIcon"><span id="storePhone" class="contactDetails"><i class="icon-phone"></i></span></div>
                <span class="contactEntry"><?php echo REVELATION_STORE_PHONE; ?></span>
            </div>
            <?php } ?>
            <?php if(defined('REVELATION_STORE_MOBILE') && REVELATION_STORE_MOBILE != '') { ?>
            <div class="contactDetailsWrapper">
                <div class="contactIcon"><span id="storeMobile" class="contactDetails"><i class="icon-mobile-phone"></i></span></div>
                <span class="contactEntry"><?php echo REVELATION_STORE_MOBILE; ?></span>
            </div>
            <?php } ?>
            <div class="contactDetailsWrapper">
                <div class="contactIcon"><span id="storeEmail" class="contactDetails"><i class="icon-envelope-alt"></i></span></div>
                <span class="contactEntry"><?php echo STORE_OWNER_EMAIL_ADDRESS; ?></span>
            </div>
        </div>
    </section>
    <?php if(REVELATION_SOCIAL_FOOTER == 'twitter'){ ?>
    <section id="twitterFooter" class="span3">
    <!-- TWITTER -->
        <h3 class="footerBoxHeading"><?php echo TEXT_TWITTER; ?></h3>
        <?php echo '<div class="footerTweet"><a class="twitter-timeline" href="https://twitter.com/'.REVELATION_TWITTER_ACCOUNT.'" data-widget-id="'.REVELATION_TWITTER_WIDGET.'" data-tweet-limit="2" data-theme="dark" data-chrome="noheader nofooter transparent">Tweets by @'.REVELATION_TWITTER_ACCOUNT.'</a></div><script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?\'http\':\'https\';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>'; ?>
    <!-- END TWITTER -->   
    </section>
    <?php }elseif(REVELATION_SOCIAL_FOOTER == 'facebook'){ ?>
    <section id="facebookFooter" class="span3">
    <!-- FACEBOOK -->
        <h3 class="footerBoxHeading"><?php echo TEXT_FACEBOOK; ?></h3>
        <div id="fb-root" style="display:none"></div>
        <script>(function(d, s, id) {var js, fjs = d.getElementsByTagName(s)[0];if (d.getElementById(id)) return;js = d.createElement(s); js.id = id;js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";fjs.parentNode.insertBefore(js, fjs);}(document, 'script', 'facebook-jssdk'));</script>
        <div class="fb-like-box" data-href="http://www.facebook.com/<?php echo REVELATION_FACEBOOK_ACCOUNT; ?>" data-show-faces="true" data-stream="false" data-border-color="#444444" data-header="false"></div>
    <!-- END FACEBOOK -->   
    </section>
    <?php }elseif(REVELATION_SOCIAL_FOOTER == 'information'){ ?>
    <section id="informationFooter" class="span3">
    <!-- INFORMATION -->
        <h3 class="footerBoxHeading"><?php echo TEXT_INFO_FOOTER; ?></h3>
        <div class="infoFooter">
            <ul class="unstyled nomargin">
                <?php foreach($information_footer as $info){ ?>
                    <li><?php echo $info; ?></li>
                <?php } ?>
            </ul>
        </div>
    <!-- END INFORMATION -->   
    </section>    
    <?php }else{ ?>
    <section id="informationFooter" class="span3">
    <!-- INFORMATION -->
        <h3 class="footerBoxHeading"><?php echo TEXT_INFO_FOOTER; ?></h3>
        <div class="infoFooter">
            <ul class="unstyled nomargin">
                <?php foreach($information_footer as $info){ ?>
                    <li><?php echo $info; ?></li>
                <?php } ?>
            </ul>
        </div>
    <!-- END INFORMATION -->   
    </section> 
    <?php } ?>
    <section id="productsFooter" class="span3">
        <h3 class="footerBoxHeading"><?php echo $footer_heading; ?></h3>
        <div id="scroller">
            <ul id="list">
            <?php while (!$products->EOF) { ?>
            <li><div class="media">
            <a class="pull-left" href="<?php echo zen_href_link(zen_get_info_page($products->fields['products_id']), 'products_id=' . $products->fields['products_id']); ?>"><?php echo zen_image(DIR_WS_IMAGES . $products->fields['products_image'], $products->fields['products_name'], 50, 50); ?></a>
            <div class="media-body">
                <p class="media-heading"><a href="<?php echo zen_href_link(zen_get_info_page($products->fields['products_id']), 'products_id=' . $products->fields['products_id']); ?>"><?php echo $products->fields['products_name']; ?></a></p>
                <p class="price"><?php echo zen_get_products_display_price($products->fields['products_id']); ?></p>
            </div>
            </div></li>
           <?php $products->MoveNext(); } ?>
            </ul>
        </div>

    </section>
</div>
</div>
<div id="bottomFooterWrapper">
<div id="bottomFooter" class="row-fluid">
    <!--bof-navigation display -->
    <div id="navSuppWrapper" class="span8">
        <div id="navSupp">
            <ul class="unstyled nomargin">
                <li><span id="siteinfoLegal" class="legalCopyright"><?php echo FOOTER_TEXT_BODY; ?></span></li>
                <?php if (EZPAGES_STATUS_FOOTER == '1' or (EZPAGES_STATUS_FOOTER == '2' and (strstr(EXCLUDE_ADMIN_IP_FOR_MAINTENANCE, $_SERVER['REMOTE_ADDR'])))) { ?>
                <li><?php require($template->get_template_dir('tpl_ezpages_bar_footer.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_ezpages_bar_footer.php'); ?></li>
                <?php } ?>
            </ul>
        </div>
        <!--bof- site copyright display -->
        
        <!--<?php if (SHOW_FOOTER_IP == '1') { ?>
            <div id="siteinfoIP"><?php echo TEXT_YOUR_IP_ADDRESS . '  ' . $_SERVER['REMOTE_ADDR']; ?></div>
        <?php } ?>-->
         <!--eof- site copyright display --> 
    </div>
        <!--eof-navigation display -->
    <div class="span4">
        <ul class="socialMedia unstyled nomargin inline pull-right">
            <?php if(defined('REVELATION_FACEBOOK_ACCOUNT') && REVELATION_FACEBOOK_ACCOUNT != '') { ?>
                <li><a href="https://www.facebook.com/<?php echo REVELATION_FACEBOOK_ACCOUNT; ?>" class="social facebook" target="_blank"><i class="icon-facebook"></i></a></li>
            <?php } ?>
            <?php if(defined('REVELATION_TWITTER_ACCOUNT') && REVELATION_TWITTER_ACCOUNT != '') { ?>
                <li><a href="https://twitter.com/<?php echo REVELATION_TWITTER_ACCOUNT; ?>" class="social twitter" target="_blank"><i class="icon-twitter"></i></a></li>
            <?php } ?>
            <?php if(defined('REVELATION_GPLUS_ACCOUNT') && REVELATION_GPLUS_ACCOUNT != '') { ?>
                <li><a href="https://plus.google.com/<?php echo REVELATION_GPLUS_ACCOUNT; ?>" class="social gplus" target="_blank"><i class="icon-google-plus"></i></a></li>
            <?php } ?>
            <?php if(defined('REVELATION_PINTEREST_ACCOUNT') && REVELATION_PINTEREST_ACCOUNT != '') { ?>
                <li><a href="http://pinterest.com/<?php echo REVELATION_PINTEREST_ACCOUNT; ?>" class="social pinterest" target="_blank"><i class="icon-pinterest"></i></a></li>
            <?php } ?>
            <?php if(defined('REVELATION_YOUTUBE_ACCOUNT') && REVELATION_YOUTUBE_ACCOUNT != '') { ?>
                <li><a href="http://youtube.com/user/<?php echo REVELATION_YOUTUBE_ACCOUNT; ?>" class="social youtube" target="_blank"><i class="icon-youtube"></i></a></li>
            <?php } ?>
            <?php if(defined('REVELATION_SKYPE_ACCOUNT') && REVELATION_SKYPE_ACCOUNT != '') { ?>
                <li><a href="skype:<?php echo REVELATION_SKYPE_ACCOUNT; ?>?call" class="social skype" target="_blank"><i class="icon-skype"></i></a></li>
            <?php } ?>
        </ul>
        <div class="clearfix"></div>   
    </div>
</div>
</div>
<?php
} // flag_disable_footer
?>